using System.ComponentModel.DataAnnotations;
using SupplierCustomerManagement.Domain.Entities;

namespace SupplierCustomerManagement.Domain.ReportForms
{
    /// <summary>
    /// 系统用户实体
    /// 用于管理系统用户信息
    /// </summary>
    public class SystemUser : BaseEntity
    {
        /// <summary>
        /// 用户名
        /// </summary>
        [Required]
        [StringLength(50)]
        public string Username { get; set; }

        /// <summary>
        /// 密码
        /// </summary>
        [Required]
        [StringLength(100)]
        public string Password { get; set; }

        /// <summary>
        /// 真实姓名
        /// </summary>
        [StringLength(50)]
        public string? RealName { get; set; }

        /// <summary>
        /// 邮箱
        /// </summary>
        [StringLength(100)]
        public string? Email { get; set; }

        /// <summary>
        /// 电话
        /// </summary>
        [StringLength(20)]
        public string? Phone { get; set; }

        /// <summary>
        /// 角色
        /// </summary>
        [StringLength(20)]
        public string? Role { get; set; }

        /// <summary>
        /// 羊场ID
        /// </summary>
        public int? FarmId { get; set; }

        /// <summary>
        /// 是否启用
        /// </summary>
        public bool IsActive { get; set; } = true;
    }
}
